package com.example.index.arch.mvvm.model

import androidx.databinding.ObservableField
import androidx.lifecycle.MutableLiveData
import androidx.lifecycle.ViewModel
import javax.inject.Inject

data class LoginResult constructor(var successful: Boolean, var msg: String)

class LoginViewModel @Inject constructor() : ViewModel() {


    val loginName = ObservableField<String>()

    val password = ObservableField<String>()


    val loginResult = MutableLiveData<String>()

    fun login() {
        loginResult.value = loginName.get() + "->" + password.get()
    }
}